package com.module.www.di;

import com.module.home.ANearbyMain;
import com.module.home.HomeActivity;
import com.module.home.NearbyFragmentDynamic;
import com.module.home.NearbyFragmentHome;
import com.module.home.NearbyFragmentMe;
import com.module.home.NearbyFragmentMessage;
import com.module.home.NearbyFragmentPrivateLetter;
import com.module.home.NearbyFragmentRelatedToMe;
import com.module.home.mvp.FragmentMainModule;
import com.module.home.mvp.FragmentMeModule;
import com.module.main.test.TemplateDaggerAct;
import com.module.main.test.TemplateDaggerAct2;
import com.module.main.test.TemplateDaggerAct2Module;
import com.module.main.test.TemplateDaggerActModule;

import dagger.Module;
import dagger.android.ContributesAndroidInjector;
import ren.nearby.http.di.BaseActivityComponent;
import ren.nearby.http.di.BaseFragmentComponent;
import ren.nearby.http.di.BaseFragmentV4Component;
import ren.nearby.http.scope.ActivityScoped;


/**
 * 配置所有activity注入
 * Created by Administrator on 2018/5/3 0003.
 */



@Module(subcomponents = {
        BaseActivityComponent.class,
        BaseFragmentComponent.class,
        BaseFragmentV4Component.class
})
public abstract class AllActivitysModule {

    @ActivityScoped
    @ContributesAndroidInjector(modules = TemplateDaggerActModule.class)
    abstract TemplateDaggerAct contributeDagger2TemplateAct();

    @ActivityScoped
    @ContributesAndroidInjector(modules = TemplateDaggerAct2Module.class)
    abstract TemplateDaggerAct2 contributeDagger2TemplateAct2();


    @ActivityScoped
    @ContributesAndroidInjector(modules = FragmentMainModule.class)
    abstract ANearbyMain aNearbyMain();

    @ActivityScoped
    @ContributesAndroidInjector(modules = FragmentMainModule.class)
    abstract HomeActivity homeActivity();



    @ActivityScoped
    @ContributesAndroidInjector(modules = FragmentMeModule.class)
    abstract NearbyFragmentHome nearbyFragmentHome();

    @ActivityScoped
    @ContributesAndroidInjector(modules = FragmentMeModule.class)
    abstract NearbyFragmentMessage nearbyFragmentMessage();

    @ActivityScoped
    @ContributesAndroidInjector(modules = FragmentMeModule.class)
    abstract NearbyFragmentMe nearbyFragmentMe();

    @ActivityScoped
    @ContributesAndroidInjector(modules = FragmentMeModule.class)
    abstract NearbyFragmentDynamic nearbyFragmentDynamic();


    @ActivityScoped
    @ContributesAndroidInjector(modules = FragmentMeModule.class)
    abstract NearbyFragmentPrivateLetter nearbyFragmentPrivateLetter();


    @ActivityScoped
    @ContributesAndroidInjector(modules = FragmentMeModule.class)
    abstract NearbyFragmentRelatedToMe nearbyFragmentRelatedToMe();

}
